#ifndef DRAWING_H
#define DRAWING_H

void floodBg(uint16 *fb, uint16 c)
{
	for(unsigned short i = 0; i < SCREEN_WIDTH * SCREEN_HEIGHT; ++i) fb[i] = c;	
}

/*void drawLine(u8 x1, u8 x2, u8 y1, u8 y2, uint16* fb, uint16 c)
{
	int xd = x2 - x1;
	int yd = y2 - y1;
	int steps = xd > yd ? xd : yd;
	
}*/

void drawShape(u8 x, u8 y, u8 width, u8 height, uint16* fb, uint16 c)
{
	// Starting point in buffer
	fb += y * SCREEN_WIDTH + x;
	for(unsigned short i = 0; i < height; ++i) {
		uint16* line = fb + (SCREEN_WIDTH * i);
		for(unsigned short j = 0; j < width; ++j) {
			*line++ = c;
		}
	}
}

#endif //DRAWING_H